package msg

import (
	"context"
	"git.mycaigou.com/gfyx/micro-gfyx-api/infrastructure/dto/base"
	"git.mycaigou.com/gfyx/micro-gfyx-api/infrastructure/repository/base/msg"
)

type MsgService struct {
	msgRepo msg.MsgRepositoryIface
}

// 构造函数
func NewMsgService(msgRepo msg.MsgRepositoryIface) MsgServiceIface {
	return &MsgService{
		msgRepo: msgRepo,
	}
}

func (s *MsgService) MsgSetReaded(ctx context.Context, msgSetReadedParam *base.MsgSetReadedParam) (int64, error) {
	return s.msgRepo.MsgSetReaded(ctx, msgSetReadedParam)
}

//// 删除消息
//func (s *MsgService) MsgDelete(ctx context.Context, param *base.MsgDeleteParams) (int64, error) {
//	return s.msgRepo.MsgDelete(ctx, param)
//}

// 消息列表
func (s *MsgService) MsgList(ctx context.Context, param *base.MsgListParam) (*base.MsgListData, error) {
	return s.msgRepo.MsgList(ctx, param)
}

//// 导入消息数据
//func (s *MsgService) MsgImport(ctx context.Context) error {
//	return s.msgRepo.MsgImport(ctx)
//}
